﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="MgmCategories.aspx.cs" Inherits="SkynetSite.Administration.MgmCategories" 
 MasterPageFile="~/Site.Master"%>
<asp:Content ID="Content1" runat="server" contentplaceholderid="MainContent">
 <asp:GridView ID="GridView1" runat="server" AllowPaging="True"  EnableViewState="False"
            AutoGenerateColumns="False" DataSourceID="ODSCategories" 
        DataKeyNames="Id" onselectedindexchanged="GridView1_SelectedIndexChanged">
            <Columns>
                <asp:CommandField ShowDeleteButton="True" ShowSelectButton="True" />
                <asp:BoundField DataField="Id" HeaderText="Id" SortExpression="Id" 
                    Visible="False" />
                <asp:BoundField DataField="Title" HeaderText="Title" SortExpression="Title" />
                <asp:BoundField DataField="Description" HeaderText="Description" 
                    SortExpression="Description" />
                <asp:BoundField DataField="OptimisticId" HeaderText="OptimisticId" 
                    SortExpression="OptimisticId" Visible="False" />
            </Columns>
        </asp:GridView>
        <br />
        <asp:DetailsView ID="DetailsView1" runat="server" AutoGenerateRows="False"  DataKeyNames="Id"
            DataSourceID="ODSWorkCategory" DefaultMode="Insert" Height="50px" Width="125px">
            <Fields>
                <asp:BoundField DataField="Id" HeaderText="Id" SortExpression="Id" 
                    Visible="False" />
                <asp:BoundField DataField="Title" HeaderText="Title" SortExpression="Title" />
                <asp:BoundField DataField="Description" HeaderText="Description" 
                    SortExpression="Description" />
                <asp:BoundField DataField="OptimisticId" HeaderText="OptimisticId" 
                    SortExpression="OptimisticId" Visible="False" />
                <asp:CommandField ShowInsertButton="True" ShowEditButton="True" />
            </Fields>
        </asp:DetailsView>
        <br />
        <asp:ObjectDataSource ID="ODSCategories" runat="server" 
            DataObjectTypeName="Skynet.BusinessEntities.ExamCategory" DeleteMethod="Delete" 
            InsertMethod="Add" OldValuesParameterFormatString="original_{0}" 
            SelectMethod="GetCategorias" 
            TypeName="Skynet.WebAdministracion.Views.CategoriesMgm.CategoriesMgmAzurePresenter" 
            UpdateMethod="Update"></asp:ObjectDataSource>
    
        <asp:ObjectDataSource ID="ODSWorkCategory" runat="server" 
            DataObjectTypeName="Skynet.BusinessEntities.ExamCategory" DeleteMethod="Delete" 
            InsertMethod="Add" OldValuesParameterFormatString="original_{0}" 
            SelectMethod="GetOne" 
            TypeName="Skynet.WebAdministracion.Views.CategoriesMgm.CategoriesMgmAzurePresenter" 
            UpdateMethod="Update">
            <SelectParameters>
                <asp:ControlParameter ControlID="GridView1" DbType="Guid" Name="Id" 
                    PropertyName="SelectedValue" />
            </SelectParameters>
        </asp:ObjectDataSource>
    
</asp:Content>

